<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean"%>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html"%>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic"%>
<%@ taglib uri="http://displaytag.sf.net/el" prefix="display"%>
<%@ taglib uri="/WEB-INF/config/tld/fmt.tld" prefix="fmt" %>
<%@ taglib uri="http://ssh.org/selects" prefix="ssh"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path;
String applicationPath = basePath + "/" + "application";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link href="<%=path%>/css/jinmu_style.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="<%=path%>/js/util.js"></script>
		<script type='text/javascript' src='<%=path%>/frame/orgSelect/js/ajaxInitSelect.js'></script>
<script language="javascript" src="<%=path%>/js/SyncCommon.js"></script>
</head>
<body>
<html:form styleId="yfApplyCostForm" action="commandFlowYfApplyCost.do?method=commandFlowYfApplyCost" onsubmit="return save();">
<html:hidden property="id" styleId="id" value="${yfApplyCost.id}"/>
<table cellspacing="0" cellpadding="0" width="98%" align="center"  border="0" class="margtb5">
		    <tr>
		      <td align="left" class="padl5 lan12"><img src="<%=path%>/images/img-11.gif" width="12" height="12"> 研发辅助 &gt; 项目费用 &gt; 费用申请 &gt; 审核</td>
		    </tr>
       </table>
	
	   
	    <table cellspacing="1" cellpadding="0" width="98%" align="center"  border="0" class="bgcolor2 margb5">
	           <tr>
		       <td colspan="2" align="left" class="bkuang zi13b bgcolor2 padl5">费用申请信息</td>
		       	     <td align="right" colspan="2">
		  
          <c:if test="${bussType==2000}">
             <input class="buttonbg" id="but_save2" style="cursor:hand;" type="button" value="修改" onclick="return checkmodify('${yfApplyCost.id}')"  name="but_save2" />
         </c:if>
        
      </td>
		    </tr>
        <tr class="bgcolor">
           <td width="18%" align="right" class="zi13"><bean:message key="com.application.yfapplycost.entity.yfapplycost.createpage.applyNo" bundle="yfapplycost"/>：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	                               				${yfApplyCost.applyNo}
		         		                       		  
	  </td>
	    <td width="18%" align="right" class="zi13"><bean:message key="com.application.yfapplycost.entity.yfapplycost.createpage.applyDate" bundle="yfapplycost"/>：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	         <bean:write name="yfApplyCost" property="applyDate" format="yyyy-MM-dd"/>
		         		                       		  
	  </td>

 
	

        </tr>
            <tr class="bgcolor">
	   <td width="18%" align="right" class="zi13">申请人：</td>
	   <td width="32%"  align="left" class="pad2 zi13"  >
	                               				${yfApplyCost.rname}
	                               				 
		         		                       		  
	  </td>

 	   <td width="18%" align="right" class="zi13">所属机构：</td>
	   <td width="32%"  align="left" class="pad2 zi13"  >
	                               				 ${yfApplyCost.org}
		         		                       		  
	  </td>
 

        </tr>
  <tr class="bgcolor">
	   <td width="18%" align="right" class="zi13"><bean:message key="com.application.yfapplycost.entity.yfapplycost.createpage.applyMoney" bundle="yfapplycost"/>(元)：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	                               				${yfApplyCost.applyMoney}
		         		                       		  
	  </td>

 
	   <td width="18%" align="right" class="zi13"><bean:message key="com.application.yfapplycost.entity.yfapplycost.createpage.feeType" bundle="yfapplycost"/>：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	         		  		  <ssh:select propertyName="feeType" pid="FEE_TYPE" type="3" defaultName="${yfApplyCost.feeType}" onChangeValue="showXM();"/>
		  
	  </td>

        </tr>
        
         <tr class="bgcolor" id="xmtr" style="display:none;">
	   <td width="18%" align="right" class="zi13">项目名称：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	                               			${yfApplyCost.projectName}
		         		                       		  
	  </td>

 
	   <td width="18%" align="right" class="zi13">项目编号：</td>
	   <td width="32%"  align="left" class="pad2 zi13">
	                               				${yfApplyCost.projectNo}
		         		                       		  
	  </td>

        </tr> 
      
        <tr class="bgcolor">
	   <td width="18%" align="right" class="zi13"><bean:message key="com.application.yfapplycost.entity.yfapplycost.createpage.applyCause" bundle="yfapplycost"/>：</td>
	   <td width="32%"  align="left" class="pad2 zi13" colspan="3">
	              ${yfApplyCost.applyCause}
		         		                       		  
	  </td>
      </tr>
   <tr>
					    <td colspan="4">
		                    <iframe width="100%" height="150px" onload="this.height=show_attachment.document.body.scrollHeight"
							src="<%=path%>/queryAttachment.do?method=queryAttachment&fid=${yfApplyCost.id}&type=10011&isShowAdd=N"
											; scrolling="no" frameborder="0" name="show_attachment"
											id="show_attachment"></iframe>       
					    </td>
					  </tr>		
 
       
 

    </table> 
 <!-- 查看意见 -->
		          	<%@ include file="/application/yfexamine/yfexmaine_list.jsp"%>
		          	
		         <c:if test="${loginUser.id!=yfApplyCost.operateid  || auditRole=='研发中心负责人'}">
					<!-- 审批意见 -->
					<%@ include file="/application/yfexamine/yfexmaine_add.jsp"%>		
			     </c:if>
		<p><p><p>
	  <table width="98%" align="center" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td align="center">
    	        <c:if test="${loginUser.id!=yfApplyCost.operateid  || auditRole=='研发中心负责人'}">
					 	  <input class="buttonbg" id="but_save2" type="submit" style="cursor:hand;" value="打回修改" onclick="return checkaction('reback')"  name="but_save2" />
						  &nbsp;&nbsp;&nbsp;
	                      <input class="buttonbg" id="but_save3" type="submit" style="cursor:hand;" value="同意" onclick="return checkaction('agree')"  name="but_save3" />
						  &nbsp;&nbsp;&nbsp;
	                       <input class="buttonbg" id="but_save2" type="submit" style="cursor:hand;" value="不同意" onclick="return checkaction('disagree')"  name="but_save2" />
			     </c:if>
			     <c:if test="${loginUser.id==yfApplyCost.operateid  && auditRole!='研发中心负责人'}">
	                       <input class="buttonbg" id="but_save2" type="submit" style="cursor:hand;" value="提交" onclick="return checkaction('modify')"  name="but_save2" />
			     </c:if>
     &nbsp;&nbsp;&nbsp;	
      <input class="buttonbg" id="but_return"  style="cursor:hand"  type="button" value="<bean:message key='com.manager.common.yfprojectapproval.return' bundle="yfprojectapproval"/>" name="but_return" onClick="javascript:history.go(-1);"/>
    </td>
  </tr>
</table>
			<html:hidden styleId="examineFlag" property="examineFlag" value="" />
			<html:hidden styleId="processId" property="processId" value="${yfApplyCost.processId}" />
			<html:hidden styleId="workItemId" property="workItemId" value="${yfApplyCost.workItemId}" />
</html:form>
</body>
</html>


<script>
<c:if test="${yfApplyCost.feeType==1 || yfApplyCost.feeType==2 || yfApplyCost.feeType==3}">
   ${"xmtr"}.style.display = "block";
</c:if>

//判断流程走向条件
function checkaction(mark){
	document.all("examineFlag").value = mark;
	//alert(document.all("result").value);
}
function save(){
	if(validateForm(document.forms[0],'Y'))
	{
		return true;
		
	}else{
	    return false;
	}
}

//转向修改页面
function checkmodify(id){
	window.open ('toUpdateIncYfApplyCost.do?method=toUpdateIncYfApplyCost&id='+id, 'newwindow', 'height=768, width=1024, top=0, left=0,toolbar=no, menubar=no, scrollbars=yes,resizable=no,location=no, status=no') 
}
</script>





